package com.ge.modules.entity;

import com.ge.modules.api.apiDTO.TbStoreCommentDto;

import java.io.Serializable;
import java.util.Date;



/**
 * 店铺评论表
 * 
 * @author lanyonglin
 * @email www.baidu.com
 * @date 2018-07-17 15:12:58
 */
public class TbStoreCommentEntity implements Serializable {
	private static final long serialVersionUID = 1L;
	
	//
	private Integer id;
	//评论者id
	private Integer userIdMaster;
	//被评论商品id
	private Integer commentIdSlave;
	//被评论店铺id
	private Integer storeIdSlave;
	//创建时间
	private Date createTime;
	//内容
	private String commentValues;
	//评论星级1-5
	private Integer starLevel;

	/**
	 * 设置：
	 */
	public void setId(Integer id) {
		this.id = id;
	}
	/**
	 * 获取：
	 */
	public Integer getId() {
		return id;
	}
	/**
	 * 设置：评论者id
	 */
	public void setUserIdMaster(Integer userIdMaster) {
		this.userIdMaster = userIdMaster;
	}
	/**
	 * 获取：评论者id
	 */
	public Integer getUserIdMaster() {
		return userIdMaster;
	}
	/**
	 * 设置：被评论商品id
	 */
	public void setCommentIdSlave(Integer commentIdSlave) {
		this.commentIdSlave = commentIdSlave;
	}
	/**
	 * 获取：被评论商品id
	 */
	public Integer getCommentIdSlave() {
		return commentIdSlave;
	}
	/**
	 * 设置：被评论店铺id
	 */
	public void setStoreIdSlave(Integer storeIdSlave) {
		this.storeIdSlave = storeIdSlave;
	}
	/**
	 * 获取：被评论店铺id
	 */
	public Integer getStoreIdSlave() {
		return storeIdSlave;
	}
	/**
	 * 设置：创建时间
	 */
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	/**
	 * 获取：创建时间
	 */
	public Date getCreateTime() {
		return createTime;
	}
	/**
	 * 设置：内容
	 */
	public void setCommentValues(String commentValues) {
		this.commentValues = commentValues;
	}
	/**
	 * 获取：内容
	 */
	public String getCommentValues() {
		return commentValues;
	}
	/**
	 * 设置：评论星级1-5
	 */
	public void setStarLevel(Integer starLevel) {
		this.starLevel = starLevel;
	}
	/**
	 * 获取：评论星级1-5
	 */
	public Integer getStarLevel() {
		return starLevel;
	}

	public TbStoreCommentDto toDto(){
		TbStoreCommentDto tbStoreCommentDto=new TbStoreCommentDto();
		tbStoreCommentDto.setCommentIdSlave(this.getCommentIdSlave());
		tbStoreCommentDto.setId(this.getId());
		tbStoreCommentDto.setUserIdMaster(this.getUserIdMaster());
		tbStoreCommentDto.setStoreIdSlave(this.getStoreIdSlave());
		tbStoreCommentDto.setCreateTime(this.getCreateTime());
		tbStoreCommentDto.setCommentValues(this.getCommentValues());
		tbStoreCommentDto.setStarLevel(this.getStarLevel());
		return tbStoreCommentDto;
	}
}
